<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@include file="/WEB-INF/common/include.jsp"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.4.0/jquery.min.js"></script> 
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
</head>
<body>
	hello world!
	<input type="button" id="test" value="jquery 异步获取json信息" />
</body>
<script type="text/javascript">

$('#test').click(function(){
	alert('jquery');
	alert('${urlPath}/test/testAction/helloJsonView');
	$.ajax({
		type:'POST',
		url:'${urlPath}/test/testAction/helloJsonView',
		cache : false ,
		dataType : 'json',
		success : function(json){
			alert('123');
			alert(json);
		},
		error : function(msg){
			alert('error');
			alert(msg.status);
			alert(msg.statusText);
			alert(msg.responseText);
		}
	});
});


</script>
</html>